import { defineNuxtConfig } from 'nuxt/config'

export default defineNuxtConfig({
    devtools: { enabled: false },
    ssr: true,
    compatibilityDate: "2025-04-10",
    devServer: {
        host: '0.0.0.0',
        port: 8002
    },
    modules: [
        '@nuxtjs/tailwindcss',
    ],
    runtimeConfig: {
        public: {
            env: 'dev',
            API_BASE_URL: {
                'dev': 'http://1.15.172.103:8888',
                'prod': 'http://md-api.helloyt.cn'
            },
        }
    },
    app: {
        head: {
            title: 'Markdown Reader',
            meta: [
                { charset: 'utf-8' },
                { name: 'viewport', content: 'width=device-width, initial-scale=1' },
            ],
            link: [
                {
                    rel: 'icon', type: 'image/x-icon', href: '/fav.ico'
                },
                { 
                    rel: 'stylesheet', 
                    href: '/fonts/font-awesome/css/font-awesome.min.css' 
                },
                { 
                    rel: 'stylesheet', 
                    href: '/markdown/markdown-it.css' 
                },
                // { rel: 'stylesheet', href: 'https://cdn.jsdelivr.net/npm/font-awesome@4.7.0/css/font-awesome.min.css' }
            ]
        }
    },
})